Showing posts with label form. Show all posts
Showing posts with label form. 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

Friday, March 9, 2012

Help needed for SSRS 2005(Regarding html code)

Hi Experts,
I am working on SSRS 2005, and I am facing a problem in this.
We are using an ASP.net application in which user fills a form. Some
fields contain text fields and we are entering all the fields in our
database through application.
But when we are entering values from application then our database
contains some html code in some fields with data.
Now I want to show those fields in my report, Values coming from
database in my report but they are in html format. So it is not
readable in report.
Now you people tell me how to solve this issue in my reports. I want
that data in my report as user entered in the application form.
Any help will be appreciated.
Regards
DineshDinesh,
The only thing I can think of is writing a function which strips out the
HTML tags and then call that function for each field in your report. You
could make this function a Report Code Block or even better, put it in an
assembly referenced by the Report.
--
Andy Potter
blog : http://sqlreportingservices.spaces.live.com
info@.(NOSPAM)lakeclaireenterprises.com
"Dinesh" <dinesht15@.gmail.com> wrote in message
news:1176467678.190725.177080@.y80g2000hsf.googlegroups.com...
> Hi Experts,
> I am working on SSRS 2005, and I am facing a problem in this.
> We are using an ASP.net application in which user fills a form. Some
> fields contain text fields and we are entering all the fields in our
> database through application.
> But when we are entering values from application then our database
> contains some html code in some fields with data.
> Now I want to show those fields in my report, Values coming from
> database in my report but they are in html format. So it is not
> readable in report.
> Now you people tell me how to solve this issue in my reports. I want
> that data in my report as user entered in the application form.
> Any help will be appreciated.
> Regards
> Dinesh
>

help needed ...to update the datatable

hi,

I have my database stored in the sqlserver 2005. Using the table name i am retrieving the table and it is displayed to the user in the form of datagridview.I am allowing the user to modify the contents of the table, including the headers. Is it possible for me to update the table straightway rather than giving a sql update command for each and every row of the table .

Pls reply asap....

-Sweety

Sure is.

Though this really isnt a SQL Issue you have. You also forgot to mention what programming language you are using (VB.NET, C# etc) If you are using the datagrid and a dataset, then its easily possible however, depending on what .net platform you are using (1.1, 2.0) if you tell us, we will be able to help further.|||

hi,

sorry for the duplicate posting.I am using VC# and .net 2.0..

bye

Sweety

help needed ! sql query

my app contains one form (aspx) and it has different controls to be filled by user (textbox,radiobutton ..etc)
it has one button which i want to use to pass values entered in these controls to other page and do some queries to sql server there (2nd page)
Now the thing is ...my controls can have NULL values ...like user could enter just one parameter and hit button
or user can fill 2 parameter and hit enter
so on the other hand (2nd page) how should i query the database accordingly ...

Example:
if (myTextBox.Text == String.Empty)
{
myParameter.Value = DBNull.Value;
}
else
{
myParameter.Value = myTextBox.Text;
}
|||

You can always use an If Else loop to write the query.
If IsDbNull(parameter) Then
parameter = (Whatever default value or just null)
Else
parameter = Request.Form("name of parameter")
End If
I hope this is clear enough.

Friday, February 24, 2012

Help me solve this.

When I collect data from a form, I recieved this message:

"Cannot create a row of size 8822 which is greater than the allowable maximum of 8060. The statement has been terminated."

Can any body tell me how to solve this, my data field is varchar size 8000 bytes, and I posted only ~ 6000 byte.Show the entire table definition, and perhaps we can help.|||There are several data types that store a fixed amount of data. For example, a char (10) field will store 10 bytes even if you never assign a value to it. So, if you have 4000 bytes worth of fixed-length fields, and you put 6000 bytes into a varchar(8000) field, you would end up with a record that's 10000 bytes and the update wil fail.