SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
Search:  
 
 
        
Home       Members    Calendar    Who's On


12345»»»

T-Sql rant Expand / Collapse
Author
Message
Posted Friday, March 13, 2009 1:54 PM


SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: 2 days ago @ 4:29 PM
Points: 128, Visits: 176
Why couldn't they write t-sql more like C# or have a flavored compiler for t-sql so that we could work it like c# or vb depending on how you like it. (or the t-sql language which really is the worst language MS has ever put on the block). I really don't understand why the sql server group didn't do a better job of it, or is it because they were taking thier queue from ORACLE.

Really stupid paradigm if you ask me, and I think it needs to be improved upon.
Post #675554
Posted Friday, March 13, 2009 2:10 PM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Yesterday @ 4:18 PM
Points: 3,074, Visits: 2,184
As it stands, T-SQL is about the most simple language on the planet. Specifically, what problems are you having that you feel are the languages fault?


Post #675563
Posted Friday, March 13, 2009 2:13 PM


SSCrazy Eights

SSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy Eights

Group: General Forum Members
Last Login: Today @ 2:02 AM
Points: 9,728, Visits: 9,571
So, what don't you like about T-SQL? I find it quite easy to work with and haven't had any problem moving from a 3GL language (COBOL) to it.

The paradigm behind SQL (T-SQL) is completely different from working with a 3GL language but make total sense when working in a set oriented environment.




Lynn Pettis

For better assistance in answering your questions, click here
For tips to get better help with Performance Problems, click here
For Running Totals and its variations, click here or when working with partitioned tables
For more about Tally Tables, click here
For more about Cross Tabs and Pivots, click here and here
Managing Transaction Logs

SQL Musings from the Desert Fountain Valley SQL (My Mirror Blog)
Post #675567
Posted Friday, March 13, 2009 2:23 PM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: Administrators
Last Login: Yesterday @ 4:33 PM
Points: 21,728, Visits: 5,982
T-SQL comes from SQL. It was developed by Sybase, not MS. It's similar to PL-SQL, which Oracle uses, but there are substantial differences.

A query language, working with sets of data, is fundamentally different than a programming languages like C#.

There are plenty of developers who think C# is a beast and a POS compared to other things. It's likely a preference thing. Each of us probably works with different types of languages and paradigms in different ways and prefers some.

I, like the others, would be interested to know what specific issues you have.
Post #675573
Posted Friday, March 13, 2009 2:27 PM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Yesterday @ 2:46 PM
Points: 7,642, Visits: 4,157
OO Querying... what would it look like:

Create Object qqMyQuery as Query;
qqMyQuery.addtable.Table1;
qqMyQuery.addtable.Table2;
qqMyQuery.addtable.Table3;
qqMyQuery.tables.addjoin(Type="Inner","Table1,Table2");
qqMyQuery.tables.joins.addcriteria(Table1.Col1,Table2.Col2);

And so on. Is something like that what you're looking for? Where you'd create objects based on definitions, and then would have to access methods and assign properties?

Frankly, I don't think that works so well. If you really want to try it out, download the free trial of Cache. It's an OO DB. Instead of tables and columns, it has objects and properties. You can do things like "MyTable.Col1.value=1", instead of the T-SQL "update MyTable set Col1 = 1". Data storage is all multi-dimensional arrays. It's designed to work with .NET directly.

If you don't like SQL, try it. Seriously.

Personally, I've done so, and I'm sticking with SQL, for the simple reason that it's a LOT easier to build and operate a database in it. For me, anyway.


- GSquared

"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
Post #675576
Posted Friday, March 13, 2009 2:29 PM


SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: 2 days ago @ 4:29 PM
Points: 128, Visits: 176
are you guys living in the cage of t-sql? :)))

well begin and end for one can be replace with { }

declare @whatever as int can be replace with
int @whatever

gee I just shortened it by two whole words.

set @i = 1 can be replaced by @i = 1 (which it has in sql 2008) about freaken time.

Shall I go on, or can you get the idea?
Post #675578
Posted Friday, March 13, 2009 2:34 PM


SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: 2 days ago @ 4:29 PM
Points: 128, Visits: 176
also instead of using cursurs like they are now, wouldn't it be easier to say:

foreach( select myfield from tbl where myotherfield > 3)
{
insert into myothertable (myotherfield) values (myfield)
}

I think it would be easier if this were the case. No GSquared, I like t-sql, but I think it could easily be made a lot more powerful if the t-sql guys would have just get off their asses and did something significant.
Post #675584
Posted Friday, March 13, 2009 2:34 PM


SSCrazy Eights

SSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy Eights

Group: General Forum Members
Last Login: Today @ 2:02 AM
Points: 9,728, Visits: 9,571
Your complaints are a bit of the mark IMHO. There is nothing wrong with the sematics of T-SQL. It's just different the C# just like C# is different from VB.NET or any of the other varied languages that exist in the world.

Now, what really bothers you about SQL?



Lynn Pettis

For better assistance in answering your questions, click here
For tips to get better help with Performance Problems, click here
For Running Totals and its variations, click here or when working with partitioned tables
For more about Tally Tables, click here
For more about Cross Tabs and Pivots, click here and here
Managing Transaction Logs

SQL Musings from the Desert Fountain Valley SQL (My Mirror Blog)
Post #675585
Posted Friday, March 13, 2009 2:36 PM


Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Today @ 1:03 PM
Points: 3,414, Visits: 8,759
the only things you identified so far is a slight shortening of a couple of keywords....saving a handful of keystrokes doesn't mean that's an improvement, just a preference.


Lowell
help us help you! if your post doesnt have CREATE TABLE YOURTABLENAME and INSERT INTO YOURTABLE SQL statements, chances are you didn't post enough information for us to help you! If you can, avoid pseudocode and show us your actual query...it makes it much better for you to see a good example with your tablenames you'd understand, and be able to copy and paste for immediate testing.
Post #675587
Posted Friday, March 13, 2009 2:37 PM


SSCrazy Eights

SSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy Eights

Group: General Forum Members
Last Login: Today @ 2:02 AM
Points: 9,728, Visits: 9,571
foxjazz (3/13/2009)
also instead of using cursurs like they are now, wouldn't it be easier to say:

foreach( select myfield from tbl where myotherfield > 3)
{
insert into myothertable (myotherfield) values (myfield)
}

I think it would be easier if this were the case. No GSquared, I like t-sql, but I think it could easily be made a lot more powerful if the t-sql guys would have just get off their asses and did something significant.


Most of us SQL guys (and gals) don't use cursors to update tables. That is SO RBAR and inefficient in SQL Server.




Lynn Pettis

For better assistance in answering your questions, click here
For tips to get better help with Performance Problems, click here
For Running Totals and its variations, click here or when working with partitioned tables
For more about Tally Tables, click here
For more about Cross Tabs and Pivots, click here and here
Managing Transaction Logs

SQL Musings from the Desert Fountain Valley SQL (My Mirror Blog)
Post #675589
« Prev Topic | Next Topic »

12345»»»

Permissions Expand / Collapse