Skip to content

Commit

Permalink
Merge pull request #81 from ventrian/feature/#80-capped-image-file-name
Browse files Browse the repository at this point in the history
Extend FileName length for images
  • Loading branch information
skamphuis authored Jul 7, 2022
2 parents e84497a + 68a90aa commit 5ff0827
Show file tree
Hide file tree
Showing 2 changed files with 84 additions and 0 deletions.
83 changes: 83 additions & 0 deletions Providers/DataProvider/SqlDataProvider/00.13.02.SqlDataProvider
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
ALTER TABLE {databaseOwner}{objectQualifier}DnnForge_NewsArticles_Image ALTER COLUMN FileName nvarchar(250) NULL
GO

ALTER PROCEDURE [dbo].[DnnForge_NewsArticles_ImageUpdate]
@ImageID int,
@ArticleID int,
@Title nvarchar(255),
@FileName nvarchar(250),
@Extension nvarchar(100),
@Size int,
@Width int,
@Height int,
@ContentType nvarchar(200),
@Folder nvarchar(200),
@SortOrder int,
@ImageGuid nvarchar(50),
@Description ntext
AS

UPDATE
dbo.DnnForge_NewsArticles_Image
SET
[ArticleID] = @ArticleID,
[Title] = @Title,
[FileName] = @FileName,
[Extension] = @Extension,
[Size] = @Size,
[Width] = @Width,
[Height] = @Height,
[ContentType] = @ContentType,
[Folder] = @Folder,
[SortOrder] = @SortOrder,
[ImageGuid] = @ImageGuid,
[Description] = @Description
WHERE
[ImageID] = @ImageID
GO

ALTER PROCEDURE [dbo].[DnnForge_NewsArticles_ImageAdd]
@ArticleID int,
@Title nvarchar(255),
@FileName nvarchar(250),
@Extension nvarchar(100),
@Size int,
@Width int,
@Height int,
@ContentType nvarchar(200),
@Folder nvarchar(200),
@SortOrder int,
@ImageGuid nvarchar(50),
@Description ntext
AS

INSERT INTO dbo.DnnForge_NewsArticles_Image (
[ArticleID],
[Title],
[FileName],
[Extension],
[Size],
[Width],
[Height],
[ContentType],
[Folder],
[SortOrder],
[ImageGuid],
[Description]
) VALUES (
@ArticleID,
@Title,
@FileName,
@Extension,
@Size,
@Width,
@Height,
@ContentType,
@Folder,
@SortOrder,
@ImageGuid,
@Description
)

select SCOPE_IDENTITY()
GO
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,7 @@
<None Include="00.07.99.SqlDataProvider" />
<None Include="00.08.00.SqlDataProvider" />
<None Include="00.08.04.SqlDataProvider" />
<None Include="00.13.02.SqlDataProvider" />
<None Include="00.13.00.SqlDataProvider" />
<None Include="00.09.02.SqlDataProvider" />
<None Include="Uninstall.SqlDataProvider" />
Expand Down

0 comments on commit 5ff0827

Please sign in to comment.