Showing posts with label path. Show all posts
Showing posts with label path. Show all posts

Friday, March 23, 2012

Help on DB design

Hi,
I have a form where users can choose number of file uploads ( drop down ) and upload images. I need to store the path of images in database.I want to know what is the best way to store multiple file upload paths. As per my knowledge it possible to store paths in one field with delimiter. Is there any other good way to store the paths.

Raj

It depends,

You have 3 (or more) options,

Store as Individual Table(rows

Each file will be stored as single row with key field.

The master table can hold the key field & number of files

Store as Delimited Value

If you use SQL server 2000, you are not allowed to store more than 8000 chars, otherwise you have to change the data type to LOB(text). In SQL Server 2005 you can use the Varchar(max).

Manipulations need to be done on the UI.

Single row modification can’t be done on the UI, you have to stick with your UI.

Store as XML value

If you use SQL Server 2005, you can use new data type XML.

You can store at any number of chars

Easy to manipulate on Database itself.

Structured & Well Managed

My Rank is – 1.XML, 2.Table(rows), 3.Delimited value

|||^Thank you Manivannan.D.Sekaran . I will follow Table(rows) as i am using sql server 2000.

Help on DB Design

Hi,
I have a form where users can choose number of file uploads ( drop down ) and upload images. I need to store the path of images in database.I want to know what is the best way to store multiple file upload paths. As per my knowledge it possible to store paths in one field with delimiter. Is there any other good way to store the paths.

Raj

Quote:

Originally Posted by bootzwiz

Hi,
I have a form where users can choose number of file uploads ( drop down ) and upload images. I need to store the path of images in database.I want to know what is the best way to store multiple file upload paths. As per my knowledge it possible to store paths in one field with delimiter. Is there any other good way to store the paths.

Raj


Generate FileId in the database and GroupId and FilePath

FileId FileGroupID FilePath
--------------------------------

Like this|||

Quote:

Originally Posted by bootzwiz

Hi,
I have a form where users can choose number of file uploads ( drop down ) and upload images. I need to store the path of images in database.I want to know what is the best way to store multiple file upload paths. As per my knowledge it possible to store paths in one field with delimiter. Is there any other good way to store the paths.

Raj


i offer to have the following entity/table for your application :

1-an entity named "Session " with these fields (SessionID,SessionName,SessionDate ) with SessionID for primary key.

2-an entity named SessionFiles with these fields(SessionID,FilenameWithPath,uploadStatus) with "SessionID,FilenameWithPath" for primary key.

3-make relation for these two table with SessionID field.

4-each form shows one session in your application for uploading the related SessionFiles.

5-Enjoy it.sql

Monday, February 27, 2012

Help me with SQL Statement

Hello, i want to make SQL statement for Restore databse that selects the
..bak file from the same .sql file path ,something like '..\' in the
javascript, plz help and thank you ..
The restore database requires absolute path. You have to determine the path
and form the restore statement.
-oj
"Samy Hamdy" <samy_hamdy@.hotmail.com> wrote in message
news:OGCsE1KfFHA.3612@.TK2MSFTNGP12.phx.gbl...
> Hello, i want to make SQL statement for Restore databse that selects the
> .bak file from the same .sql file path ,something like '..\' in the
> javascript, plz help and thank you ..
>
|||Thank you very much ..

Help me with SQL Statement

Hello, i want to make SQL statement for Restore databse that selects the
.bak file from the same .sql file path ,something like '..\' in the
javascript, plz help and thank you ..The restore database requires absolute path. You have to determine the path
and form the restore statement.
-oj
"Samy Hamdy" <samy_hamdy@.hotmail.com> wrote in message
news:OGCsE1KfFHA.3612@.TK2MSFTNGP12.phx.gbl...
> Hello, i want to make SQL statement for Restore databse that selects the
> .bak file from the same .sql file path ,something like '..' in the
> javascript, plz help and thank you ..
>|||Thank you very much ..

Help me with SQL Statement

Hello, i want to make SQL statement for Restore databse that selects the
.bak file from the same .sql file path ,something like '..\' in the
javascript, plz help and thank you ..The restore database requires absolute path. You have to determine the path
and form the restore statement.
--
-oj
"Samy Hamdy" <samy_hamdy@.hotmail.com> wrote in message
news:OGCsE1KfFHA.3612@.TK2MSFTNGP12.phx.gbl...
> Hello, i want to make SQL statement for Restore databse that selects the
> .bak file from the same .sql file path ,something like '..\' in the
> javascript, plz help and thank you ..
>|||Thank you very much ..