Quantcast
Channel: Extract values from the String filed in SQL server
Browsing all 34 articles
Browse latest View live

Extract values from the String filed in SQL server

Hi Red987,Agreed with other experts, it is better for you to create one index on your source table, preferably a clustered index.Then the performance could be better during your query.Or you could have...

View Article



Extract values from the String filed in SQL server

@Guoxiong, The current source table doesn't have any primary key.Then you should not try batching. Batching requires that there is an index you can do the batching over. Preferably a clustered...

View Article

Extract values from the String filed in SQL server

@Naomi, will do. Thanks!

View Article

Extract values from the String filed in SQL server

@Guoxiong, The current source table doesn't have any primary key.

View Article

Extract values from the String filed in SQL server

I have large table with around 50million data that needs to be updated and inserted into then final table. My approach was to apply transformations and then load into temp table and finally loaded data...

View Article


Extract values from the String filed in SQL server

Hi,I believe I posted some samples in the past and you can also find samples in that forum, just do a search for 'INSERT BATCHES SQL SERVER' (for example).Looking for new opportunitiesFor every expert,...

View Article

Extract values from the String filed in SQL server

@Naomi, thanks for responding! Could you please help me out in sending the sample query to load in batches? Even it takes longer time to load from temp to permanent as well?Thanks in advance!

View Article

Extract values from the String filed in SQL server

Try using batches approach for loading into temp table and then back. It's not going to be quick for 50 mln rows, I think 10 min. is probably fine.Looking for new opportunitiesFor every expert, there...

View Article


Extract values from the String filed in SQL server

@Melissa, I am seeing the performance issues with below the logic: selectcasewhen CHARINDEX('Number="',htmlString)>0then...

View Article


Extract values from the String filed in SQL server

Hi Red987, Could you please provide any update ? Please remember to mark the replies as answers if they helped. Your action would be helpful to other users who encounter the same issue and read this...

View Article

Extract values from the String filed in SQL server

Thanks for responding. I am getting this error "Invalid length parameter passed to the LEFT or SUBSTRING function" for below set of data:  Sample data for string: Number of Sales: <Area="XBA"...

View Article

Image may be NSFW.
Clik here to view.

Extract values from the String filed in SQL server

Hi Red987,Please also find another method which has the same query cost with Naomi's query from below.declare @t table (ID int identity(1,1) primary key, htmlString nvarchar(max)) insert into @t...

View Article

Image may be NSFW.
Clik here to view.

Extract values from the String filed in SQL server

Hi Naomi,>> "...Tried both solutions in one batch (and displayed the actual execution plan just to see the winner):..."Is it taking into account maintainability?Some interesting stats: And the...

View Article


Extract values from the String filed in SQL server

Tried both solutions in one batch (and displayed the actual execution plan just to see the winner):declare @t table (ID int identity(1,1) primary key, htmlString nvarchar(max)) insert into @t...

View Article

Extract values from the String filed in SQL server

Hi Naomi, I added a 5th row ('No Sales were happened: SPANISH<UV>END'); My T-SQL stays rock solid. Everything continues to work without any code change.

View Article


Extract values from the String filed in SQL server

Try this:declare @t table (ID int identity(1,1) primary key, htmlString nvarchar(max)) insert into @t (htmlString) values ('Number of Sales: <Area="ABC"...

View Article

Extract values from the String filed in SQL server

Hi Naomi,I added a 4th row ('No pattern at all');.My T-SQL stays rock solid. Everything continues to work without any code change.Please give it a shot.

View Article


Extract values from the String filed in SQL server

@Naomi, Sorry the issue is not due to below sample data: Number of Sales: <Area="XBA" Number="">0</a><XX>ENDThe issue is because of the this kind of data in the same field.No Sales...

View Article

Extract values from the String filed in SQL server

I've adjusted the code, I'm getting null if the pattern doesn't match:declare @t table (ID int identity(1,1) primary key, htmlString nvarchar(max)) insert into @t (htmlString) values ('Number of Sales:...

View Article

Extract values from the String filed in SQL server

CREATE TABLE #temp ( ID int, Sales nvarchar (MAX) ) INSERT INTO #temp VALUES (1,'Number of Sales: <Area="ABC" Number="1012,1013,1014,1015">4</a><ZZ>END'), (2,'Number of Sales:...

View Article
Browsing all 34 articles
Browse latest View live




Latest Images