Viewing 15 posts - 2,536 through 2,550 (of 3,480 total)
Ouch. Explain what you're trying to accomplish. You can probably do this with a Tally or "numbers" table and a simple query.
May 4, 2015 at 9:39 am
/* remove City and State from the Address */
SELECT Address
, LEFT(Address,CHARINDEX(',',Address,1)-1) AS StreetAddr
, RIGHT(Address,2) AS AddrState
FROM Address1;
April 30, 2015 at 7:50 pm
full weeks since when? the first of the year?
Maybe Lynn Pettis' article will help:
http://www.sqlservercentral.com/blogs/lynnpettis/2009/03/25/some-common-date-routines/
April 30, 2015 at 3:09 pm
I would probably start with Dwain Camps' article here:
http://www.sqlservercentral.com/articles/String+Manipulation/94365/
I might go about it by writing all the locations (use CharIndex) of a string to a temp table and then doing...
April 30, 2015 at 11:51 am
STDistance returns the straight line distance between two points (as the crow flies). GoogleMaps determines the distance by the sum of the lengths of sections of roads traveled on....
April 29, 2015 at 10:51 pm
I would be wary of a design like that. How would you deny update/delete on a table if you had all of your stored procedures like that? If they...
April 29, 2015 at 5:56 pm
<zing!>
Sorry, missed that COMPLETELY.
April 28, 2015 at 9:46 pm
Save yourself the headache. Store the dates as dates, not as two columns with numbers. Then you can do date math really easily, index columns and all that....
April 28, 2015 at 9:02 pm
What are you trying to do? Filter the report so they only see the records they want? That's pretty easy.
Or are you trying to make the fields in your...
April 27, 2015 at 9:43 pm
Not near enough information to help.
What does the signature of the stored procedure form Oracle look like?
storedproc_name
@param1 <datatype>,
@param2 <datatype>
If the stored procedure already has paramters, are you trying to use...
April 27, 2015 at 11:27 am
By far the easiest way of dealing with stuff like this is by using a Calendar table. Then you can get ANY day of ANY week...
SELECT ..
FROM CalendarTable
WHERE WeekNumber...
April 23, 2015 at 5:27 pm
Why not just cascade the parameters?
First one is Elementary/Middle/High School
Second filters based on that.
SELECT Grade FROM src WHERE Level = @Parameters!Level
April 23, 2015 at 8:18 am
Think if it this way:
T-SQL does all the data manipulation
VBA does the front end stuff (if you're using something like an Access FE and a SQL Server BE) -- pretty...
April 22, 2015 at 9:25 pm
Not sure if it's possible, but one way might be to use an ADO connection from inside Excel to push the results to SQL Server...
April 18, 2015 at 10:25 am
Viewing 15 posts - 2,536 through 2,550 (of 3,480 total)