473,320 Members | 1,848 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Parameter value from empty text box - null or 0 length?

Hi,
I run a stored procedure with a parameter given from a text box in an access
adp. If the text box is empty then what is passed to the parameter? I can't
seem to get it to flag up as either null, or 0 length.

Any tips?
Cheers,
Chris
Jul 20 '05 #1
1 2261
Hi

NULL does is not the same as an empty string!

Do you know what value it is passing? It may be a single space? Using
profiler would show the command being executed on your server. Depending on
how you are trying to create the command being sent to SQL Server will
determine what you can do. Using the NULLIF function along with RTRIM may
solve your problem if you are using a passthrough query.

John
"Not Me" <No****@faker.fake.fa.kee> wrote in message
news:cb**********@ucsnew1.ncl.ac.uk...
Hi,
I run a stored procedure with a parameter given from a text box in an access adp. If the text box is empty then what is passed to the parameter? I can't seem to get it to flag up as either null, or 0 length.

Any tips?
Cheers,
Chris

Jul 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: tornado | last post by:
Hi all, I am pretty new to PHP. I was reading PHP manual and trying out the example from 2nd chapter (A simple Tutorial). When i try to print the variable as given in the example it returns...
4
by: Dan | last post by:
I've run into an interesting problem, and seemed to have stumped 3 newsgroups and 2 other forums. For some reason when I try to insert a record into a SQL table that has a Text column, the...
21
by: Michael Bierman | last post by:
Please forgive the simplicy of this question. I have the following code which attempts to determine the color of some text and set other text to match that color. It works fine in Firefox, but does...
2
by: Jack | last post by:
It appears that RecordsAffected reports the wrong value when a Null integer or date value is inserted using empty quotes. The insert works fine, but RecordsAffected reports 0 instead of 1. Here...
5
by: Jet | last post by:
Hi all, I had a code like the follow: class A{ ... public void get(int i,params OleDbParameter p) { if((p!=null)||(p.Length>0)) { // Do some work }
2
by: DazedAndConfused | last post by:
I converted a C# example of using dll crypt32 to VB .NET. The converted example fails when Encypting/Decypting. I found that if instead of defining a variable as and setting the values for...
2
by: manmit.walia | last post by:
Hello All and Thank You for your time, I am stuck on this exception handleing error. The problem is that when I run my application the application works perfect but sometimes, I get this error. I...
2
by: simon | last post by:
hello, new to vb.net, have a few questions about DataGrid. I have a dataGrid that is working pulling a dataset back from a stored proc and binding to the datagrid for display the datagrid's...
7
by: =?ISO-8859-2?Q?Gregor_Kova=E8?= | last post by:
Hi! Is it possible to use parameter markers like this: 1.) SELECT * FROM TABLE1 WHERE FIELD1 LIKE '%?%' If I now set parameter 1 to '' (empty string) I don't get any rows back, but if I run:...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.