Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

1) Compare text fields in SQL Server, 2) Web Publishing Database

Posted on 2003-11-11
5
Medium Priority
?
2,975 Views
Last Modified: 2007-12-19
Hi guys! I see you are doing a great job out there!
I have read some answers and I wanted to post one or two of mine:
1) Is it possible to use <, >, = (ie compare) text fields in SQL Server? One of the columns in my database is text data type and I cannot thing of any other way than using like and putting each value separately. Is there any other way?
2) What is the best way to publish a table on the Web? My database is SQL Server 2000 and I am using Visual Basic 6 for my projects. So, HTML, right from SQL Server, of XML? Does Visual Basic 6 support XML?
Thanks in advance!
0
Comment
Question by:patrickdrd
  • 2
5 Comments
 
LVL 1

Accepted Solution

by:
eriker earned 300 total points
ID: 9722163
Q1) Yes, you can use > and < to compare text fields in SQL-server.

"Select * from employees where firstname < 'B' " will only give you the employees whose firstname starts with an 'A'

Q2) Are you familiar with VB-scripting? In that case, a connection to your SQL-server from an ASP-page to display data from a tabla is one solution.
0
 
LVL 7

Assisted Solution

by:wsteegmans
wsteegmans earned 300 total points
ID: 9726548
Q1)
Indeed, you can! But pay attention, you're doing just a string-compare, so when comparing, you will get this result ...
'str100' < 'str1000' < 'str2'

Q2)
In SQL Server 2000, there is an additional pack for XML support: SQLXML. So, download it first (SQLXML 3.0 SP2)
http://www.microsoft.com/downloads/details.aspx?FamilyId=4C8033A9-CF10-4E22-8004-477098A407AC&displaylang=en

In the Online Books of SQL-Server, or the MSDN-Chapters, you find a lot of information about querying the SQL-Server with XML as output. You can also create an XSL StyleSheet, so you're output is formatted ...

Here, one article (in MSDN): Accessing SQL Server Using HTTP
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/xmlsql/ac_xml1_59m4.asp
0
 
LVL 7

Expert Comment

by:wsteegmans
ID: 9791649
patrickdrd,

Please respond to the answers and give us additional info ...
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Microsoft Access is a place to store data within tables and represent this stored data using multiple database objects such as in form of macros, forms, reports, etc. After a MS Access database is created there is need to improve the performance and…
Lotus Notes has been used since a very long time as an e-mail client and is very popular because of it's unmatched security. In this article we are going to learn about  RRV Bucket corruption and understand various methods to Fix "RRV Bucket Corrupt…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
Suggested Courses

927 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question