Ошибка user does not exist

Symptoms

Logging in, deleting, or editing a user is not possible even though the user exists on the user management tab. Editing the user returns a stack trace in the page, and deleting it results in the following error:
 

In the below screen «user001» was provisioned but its directory and avatar do not exist. Logging in, editing, and deleting this user fails via User Management and API.

In some cases, the following appears in the atlassian-jira.log:

atlassian-jira.log

2013-07-01 17:20:32,465 http-bio-8090-exec-4 ERROR      [500ErrorPage.jsp] Exception caught in 500 page null
java.lang.NullPointerException
	at com.atlassian.jira.web.action.admin.user.EditUser.buildNewUser(EditUser.java:106)
	at com.atlassian.jira.web.action.admin.user.EditUser.doValidation(EditUser.java:57)
	at webwork.action.ActionSupport.validate(ActionSupport.java:391)
	at webwork.action.ActionSupport.execute(ActionSupport.java:162)
	at com.atlassian.jira.action.JiraActionSupport.execute(JiraActionSupport.java:83)  <+7> (DefaultInterceptorChain.java:39) (NestedInterceptorChain.java:31) (ChainedInterceptor.java:16) (DefaultInterceptorChain.java:35) (GenericDispatcher.java:225) (GenericDispatcher.java:154) (JiraWebworkActionDispatcher.java:151)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)  <+14> (ApplicationFilterChain.java:305) (ApplicationFilterChain.java:210) (ChainedFilterStepRunner.java:84) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (XContentTypeOptionsNoSniffFilter.java:22) (AbstractHttpFilter.java:31) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (HeaderSanitisingFilter.java:44) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (IteratingFilterChain.java:46) (DelegatingPluginFilter.java:66)
	at com.atlassian.translations.inproduct.components.ServletFilter.doFilter(ServletFilter.java:31)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.labs.botkiller.BotKillerFilter.doFilter(BotKillerFilter.java:36)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.jira.tzdetect.IncludeResourcesFilter.doFilter(IncludeResourcesFilter.java:39)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.jira.baseurl.IncludeResourcesFilter.doFilter(IncludeResourcesFilter.java:38)  <+8> (AbstractHttpFilter.java:31) (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66) (ContextFilter.java:25) (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.mywork.client.filter.ServingRequestsFilter.doFilter(ServingRequestsFilter.java:37)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.prettyurls.filter.PrettyUrlsDispatcherFilter.doFilter(PrettyUrlsDispatcherFilter.java:60)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.prettyurls.filter.PrettyUrlsSiteMeshFilter.doFilter(PrettyUrlsSiteMeshFilter.java:92)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.prettyurls.filter.PrettyUrlsMatcherFilter.doFilter(PrettyUrlsMatcherFilter.java:56)  <+20> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (ServletFilterModuleContainerFilter.java:77) (ServletFilterModuleContainerFilter.java:63) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (AccessLogFilter.java:103) (AccessLogFilter.java:87) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (XsrfTokenAdditionRequestFilter.java:54) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (SiteMeshFilter.java:129) (SiteMeshFilter.java:77) (SitemeshPageFilter.java:124) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (IteratingFilterChain.java:46) (DelegatingPluginFilter.java:66)
	at com.atlassian.plugin.remotable.plugin.module.permission.ApiScopingFilter.doFilter(ApiScopingFilter.java:62)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61)  <+22> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (ServletFilterModuleContainerFilter.java:77) (ServletFilterModuleContainerFilter.java:63) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (SecurityFilter.java:234) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (TrustedApplicationsFilter.java:98) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (BaseLoginFilter.java:169) (JiraLoginFilter.java:70) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (IteratingFilterChain.java:46) (DelegatingPluginFilter.java:66) (OAuthFilter.java:55) (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.bonfire.web.filters.BonfireP3PFilter.doFilter(BonfireP3PFilter.java:57)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61)  <+13> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (ServletFilterModuleContainerFilter.java:77) (ServletFilterModuleContainerFilter.java:63) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (ProfilingFilter.java:99) (JIRAProfilingFilter.java:19) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (AbstractJohnsonFilter.java:71) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210)
	at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176)
	at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145)
	at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92)  <+9> (UrlRewriteFilter.java:394) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (GzipFilter.java:80) (GzipFilter.java:51) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (IteratingFilterChain.java:46) (DelegatingPluginFilter.java:66)
	at com.atlassian.plugin.remotable.plugin.module.oauth.OAuth2LOFilter.doFilter(OAuth2LOFilter.java:70)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.plugin.remotable.host.common.service.http.bigpipe.BigPipeRequestIdFilter.doFilter(BigPipeRequestIdFilter.java:33)  <+3> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66)
	at com.atlassian.prettyurls.filter.PrettyUrlsCombinedMatchDispatcherFilter.doFilter(PrettyUrlsCombinedMatchDispatcherFilter.java:61)  <+41> (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (DelegatingPluginFilter.java:66) (JWDSendRedirectFilter.java:25) (DelegatingPluginFilter.java:74) (IteratingFilterChain.java:42) (ServletFilterModuleContainerFilter.java:77) (ServletFilterModuleContainerFilter.java:63) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (ChainedFilterStepRunner.java:84) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (AbstractCachingFilter.java:33) (AbstractHttpFilter.java:31) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (AbstractEncodingFilter.java:41) (AbstractHttpFilter.java:31) (PathMatchingEncodingFilter.java:49) (AbstractHttpFilter.java:31) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (JiraStartupChecklistFilter.java:74) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (ChainedFilterStepRunner.java:84) (JiraFirstFilter.java:57) (ApplicationFilterChain.java:243) (ApplicationFilterChain.java:210) (StandardWrapperValve.java:225) (StandardContextValve.java:123) (AuthenticatorBase.java:472) (StandardHostValve.java:168) (ErrorReportValve.java:98) (StandardEngineValve.java:118) (AccessLogValve.java:927) (CoyoteAdapter.java:407) (AbstractHttp11Processor.java:1001) (AbstractProtocol.java:585) (JIoEndpoint.java:312)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:724)

Diagnosis 1

The user can be successfully seen, edited or the user can log in successfully on other nodes in Jira DC or none of the nodes in some cases. Below SQL does not return this user’s name in the result set. 

SELECT lower_user_name FROM cwd_user
	WHERE lower_user_name NOT IN (SELECT lower_user_name FROM app_user); 

If the above SQL returns the user’s name in the result set please refer to this article Jira throws error user exists but has no unique key mapping on login

Diagnosis 2

Run the following query against the JIRA database to verify if this is indeed happens due to a username containing a line break:

PostgreSQL:

SELECT * FROM cwd_user WHERE user_name LIKE '%
%';

SQL Server:

SELECT * FROM cwd_user WHERE user_name LIKE '%'+CHAR(10)+'%';

Cause 1

The user cache on the Jira node or nodes is not flushed successfully.

Cause 2

This happens because the user contains a line break in its username. The most likely reason for this to occur is importing a malformed CSV file which contains the line break in the user’s name (JIM-1001). JIRA not being able to handle this is being tracked on JRA-33690.

Workaround 1

Refresh the User’s Cache

Restarting Jira will clear the user’s cache and recreate it once the application is started again.
(info) If you have a Data Center installation, all Nodes must be stopped at the same time  leaving no running nodes and then started one by one , otherwise the problematic cache can be replicated back to the starting Nodes.

Workaround 2

To avoid downtime to production servers, we highly recommended to verify this in a test or staging instance first.

  1. Generate an XML backup of your JIRA instance from Administration -> System > Backup System.
  2. Unzip/extract the backup ZIP file to get two XML files activeobjects.xml and entities.xml.
  3. Open the XML files in a text editor.
  4. Use the ‘Find and Replace’ feature of the text editor to replace e.g. ‘Matheus
    Fernandes’ with ‘matheusfernandes’;
  5. Save the XML files.
  6. ZIP/compress the files together again.
  7. Re-import the modified backup ZIP file into JIRA from Administration -> System > Restore System.

Когда я запускаю следующий запрос, я получаю сообщение об ошибке:

SELECT `a`.`sl_id` AS `sl_id`, `a`.`quote_id` AS `quote_id`, `a`.`sl_date` AS `sl_date`, `a`.`sl_type` AS `sl_type`, `a`.`sl_status` AS `sl_status`, `b`.`client_id` AS `client_id`, `b`.`business` AS `business`, `b`.`affaire_type` AS `affaire_type`, `b`.`quotation_date` AS `quotation_date`, `b`.`total_sale_price_with_tax` AS `total_sale_price_with_tax`, `b`.`STATUS` AS `status`, `b`.`customer_name` AS `customer_name` FROM `tbl_supplier_list` `a` LEFT JOIN `view_quotes` `b` ON (`b`.`quote_id` = `a`.`quote_id`) LIMIT 0, 30 

Сообщение об ошибке:

#1449 - The user specified as a definer ('web2vi'@'%') does not exist 

Почему я получаю эту ошибку? Как это исправить?

Ответ 1

Это обычно происходит при экспорте представлений/триггеров/процедур из одной базы данных или сервера в другой, поскольку пользователь, создавший этот объект, больше не существует.

У вас есть два варианта:

1. Измените DEFINER

Это, возможно, проще всего сделать при первоначальном импорте объектов базы данных, удалив любые операторы DEFINER из дампа.

Изменение определителя позже является более сложным:

Как изменить определитель для представлений

  • Запустите этот SQL для генерации необходимых операторов ALTER

    SELECT CONCAT("ALTER DEFINER=`youruser`@`host` VIEW ", table_name, " AS ", view_definition, ";") FROM information_schema.views WHERE table_schema='your-database-name'; 
  • Скопируйте и запустите инструкции ALTER

Как изменить определитель для хранимых процедур

Пример:

UPDATE `mysql`.`proc` p SET definer = '[email protected]%' WHERE definer='[email protected]%'

Будьте осторожны, потому что это изменит все определители для всех баз данных.

2. Создайте отсутствующего пользователя

Если вы обнаружили следующую ошибку при использовании базы данных MySQL:

The user specified as a definer ('someuser'@'%') does not exist`

Тогда вы можете решить это, используя следующее:

GRANT ALL ON *.* TO 'someuser'@'%' IDENTIFIED BY 'complex-password';
FLUSH PRIVILEGES;

Из http://www.lynnnayko.com/2010/07/mysql-user-specified-as-definer-root.html

Это работало как шарм — вам нужно только изменить someuser на имя пропавшего пользователя. На локальном сервере-разработчике обычно можно использовать root.

Также рассмотрите вопрос о том, действительно ли вам нужно предоставить разрешения пользователя ALL или они могут сделать меньше.

Ответ 2

Пользователь, который изначально создал представление или процедуру SQL, был удален. Если вы воссоздаете этого пользователя, он должен устранить вашу ошибку.

Ответ 3

Я получил ту же ошибку после обновления mysql.

Ошибка была исправлена после этой команды:

mysql_upgrade -u root

mysql_upgrade должен выполняться каждый раз при обновлении MySQL. Он проверяет все таблицы во всех базах данных на предмет несовместимости с текущей версией MySQL Server. Если найденная таблица имеет возможную несовместимость, она проверяется. Если обнаружены какие-либо проблемы, таблица будет восстановлена. mysql_upgrade также обновляет системные таблицы, чтобы вы могли использовать новые привилегии или возможности, которые могли быть добавлены.

Ответ 4

Если пользователь существует, то:

mysql> flush privileges;

Ответ 5

Создайте удаляемого пользователя следующим образом:

mysql> create user 'web2vi';

или

mysql> create user 'web2vi'@'%';

Ответ 6

Выполните следующие действия:

  • Перейдите в PHPMyAdmin
  • Выберите свою базу данных
  • Выберите таблицу
  • В верхнем меню Нажмите «Триггеры»
  • Нажмите «Изменить», чтобы изменить триггер
  • Измените определитель с [user @localhost] на root @localhost

Надеюсь, что это поможет

Ответ 7

Решение — это всего лишь однострочный запрос, как показано ниже:

grant all on *.* to 'ROOT'@'%' identified by 'PASSWORD' with grant option;

Замените ROOT своим именем пользователя mysql.
Замените PASSWORD своим паролем mysql.

Ответ 8

Для будущих googlers: у меня есть аналогичное сообщение, пытающееся обновить таблицу в базе данных, которая не содержит представлений. После некоторого копания оказалось, что я импортировал триггеры на эту таблицу, и это были вещи, определенные несуществующим пользователем. Сбрасывание триггеров решило проблему.

Ответ 9

Исправлено, выполнив следующие комментарии.

grant all on *.* to 'web2vi'@'%' identified by 'root' with grant option;
FLUSH PRIVILEGES;

если вы получаете some_other вместо web2vi, тогда вы должны соответствующим образом изменить имя.

Ответ 10

быстро исправить работу и выгрузить файл:

mysqldump --single-transaction -u root -p xyz_live_db > xyz_live_db_bkup110116.sql

Ответ 11

Пользователь ‘web2vi’ не существует на вашем сервере mysql.

См. http://dev.mysql.com/doc/refman/5.1/en/error-messages-server.html#error_er_no_such_user

Если этот пользователь существует, проверьте, на каких серверах он может получить доступ, хотя я бы подумал, что это будет другая ошибка (например, у вас может быть web2vi @localhost, но вы получаете доступ к db как web2vi @% (во что угодно )

Ответ 12

У меня была такая же проблема с пользователем root, и он работал у меня, когда я заменил

[email protected]%

по

[email protected]

Итак, если пользователю ‘web2vi’ разрешено подключаться из ‘localhost’, вы можете попробовать:

[email protected]

Я подключен удаленно к базе данных.

Ответ 13

grant all on *.* to 'username'@'%' identified by 'password' with grant option;

Пример:

grant all on *.* to 'web2vi'@'%' identified by 'password' with grant option;

Ответ 14

Это случилось со мной после перемещения БД с одного сервера на другой. Первоначально определитель использовал localhost и пользователя. На новом сервере у нас нет этого пользователя, и хост также был изменен. Я сделал резервную копию этой конкретной таблицы и вручную удалил все триггеры из phpmyadmin. После этого он работал нормально для меня.

Ответ 15

Мои 5 центов.

У меня была такая же ошибка, когда я пытался выбрать из представления.

Однако проблема заключается в том, что это представление, выбранное из другого представления, которое было восстановлено из резервной копии с другого сервера.

и на самом деле, ДА, пользователь был недействителен, но не был очевиден с первого взгляда.

Ответ 16

Попробуйте установить процедуру как
SECURITY INVOKER

Mysql default устанавливает безопасность процедур как «DEFINER» (CREATOR OF).. вы должны установить защиту для «invoker».

Ответ 17

У меня была одна и та же проблема минут назад, я столкнулся с этой проблемой после того, как удалил неиспользуемого пользователя из таблицы mysql.user, но вместо этого изменил его вид, вот удобная команда, которая делает ее очень простой:

SELECT CONCAT("ALTER DEFINER=`youruser`@`host` VIEW ",
table_name," AS ", view_definition,";") FROM 
information_schema.views WHERE table_schema='databasename'

Смешайте это с командной строкой mysql (предполагая * nix, не знакомый с окнами):

> echo above_query | mysql -uuser -p > alterView.sql
> mysql -uuser -ppass databasename < alterView.sql

Примечание: команда генерирует и добавляет SELECT CONCAT в файл, делая mysql -uuser -ppass databasename < alterView.sql сбой, если вы не удалите его.

Источник: https://dba.stackexchange.com/questions/4129/modify-definer-on-many-views

Ответ 18

Ваше мнение, «view_quotes», возможно, было скопировано из другой базы данных, где «web2vi» является допустимым пользователем в базе данных, где «web2vi» не является допустимым пользователем.
Либо добавьте пользователя «web2vi» в базу данных, либо измените представление (обычно удаление части DEFINER = ‘web2vi’ @’%’ и выполнение script сделает трюк)

Ответ 19

В моем случае таблица имела триггер с пользователем DEFINER, которого не было.

Ответ 20

Проблема понятна — MySQL не может найти пользователя, заданного в качестве определителя.

Я столкнулся с этой проблемой после синхронизации модели базы данных с сервера разработки, применения ее к localhost, внесения изменений в модель и последующего повторного использования ее на localhost. По-видимому, было определено представление (я изменил), и поэтому я не смог обновить локальную версию.

Как исправить (легко) :

Примечание: он включает удаление, поэтому он отлично подходит для представлений, но убедитесь, что у вас есть резервная копия данных, если вы попробуете это в таблицах.

  • Войдите в базу данных как пользователь root (или все, что имеет достаточную мощность для внесения изменений).
  • Удалить представление, таблицу или все, с чем вы столкнулись.
  • Синхронизируйте свою новую модель — она ​​не будет жаловаться на то, чего не существует сейчас. Вы можете удалить часть SQL SECURITY DEFINER из определения элемента, с которым у вас были проблемы.

P.S. Это не является ни правильным, ни лучшим решением. Я просто разместил его как возможное (и очень простое) решение.

Ответ 21

Вы можете попробовать следующее:

$ mysql -u root -p 
> grant all privileges on *.* to `root`@`%` identified by 'password'; 
> flush privileges;

Ответ 22

Почему я получаю эту ошибку? Как это исправить?

Я потратил час до того, как нашел решение для такой проблемы. Но в моем случае я запустил это:

mysql> UPDATE `users` SET `somefield` = 1 WHERE `user_id` = 2;
ERROR 1449 (HY000): The user specified as a definer ('root'@'%') does not exist

Если вы действительно хотите найти проблему, просто запустите следующие команды:

SHOW PROCEDURE STATUS;
SHOW FUNCTION STATUS;
SHOW TRIGGERS;
SHOW FULL TABLES IN database_name WHERE TABLE_TYPE LIKE 'VIEW';

… и после каждого из них найдите поле «определитель».

В моем случае это был бородатый старый триггер, который кто-то из разработчиков забыл удалить.

Ответ 23

От ссылка MySQL CREATE VIEW:

В предложениях DEFINER и SQL SECURITY указан контекст безопасности, который будет использоваться при проверке прав доступа во время вызова представления.

Этот пользователь должен существовать и всегда лучше использовать «localhost» в качестве имени хоста. Поэтому я думаю, что если вы проверите, что пользователь существует и измените его на «localhost» при создании представления, у вас не будет этой ошибки.

Ответ 24

Перейдите в раздел подпрограммы редактирования, а внизу измените тип безопасности с Definer на Invoker.

Ответ 25

Один или несколько видов, созданных/зарегистрированных другим пользователем. Вам нужно будет проверить владельца представления и:

  • Восстановить пользователя; как говорят другие ответы.
    или
  • Создайте представления, созданные пользователем 'web2vi', используя ALTER VIEW

У меня была эта проблема.

Я пытался перенести представления из BD1 в BD2, используя SQLYog. SQLYog воссоздал представления в другой базе данных (DB2), но он сохранил пользователя BD1 (они разные). Позже я понял, что представления, которые я использовал в моем запросе, имели ту же ошибку, что и вы, даже когда я не создавал никакого представления.

Надеюсь на эту помощь.

Ответ 26

Если это хранимая процедура, вы можете сделать:

UPDATE `mysql`.`proc` SET definer = 'YournewDefiner' WHERE definer='OldDefinerShownBefore'

Но это не рекомендуется.

Для меня лучшим решением является создание определителя:

create user 'myuser' identified by 'mypass';
grant all on `mytable`.* to 'myuser' identified by 'mypass';

Ответ 27

когда mysql.proc пуст, но система всегда замечает «[email protected]%» для имени таблицы, нет, вы просто root в командной строке mysql и введите:

CHECK TABLE `database`.`table_name` QUICK FAST MEDIUM CHANGED;
flush privileges;

над

Ответ 28

Это произошло со мной после того, как я импортировал дамп в Windows 10 с MySQL Workbench 6.3 Community, а «root @% не существует». Хотя пользователь существовал.
Сначала я попытался прокомментировать DEFINER, но это не сработало.
Затем я заменил строку «root @%» на «root @localhost» и повторно импортировал дамп. Это сделало трюк для меня.

Ответ 29

Пользователь базы данных также, похоже, чувствителен к регистру, поэтому, когда у меня был пользователь root @@%, у меня не было пользователя ROOT ‘@’%. Я изменил пользователя на верхний регистр с помощью инструментария, и проблема была решена!

Ответ 30

в моем случае у меня был триггер в этой таблице, что я не мог обновлять данные, получая ту же ошибку.

Ошибка MySQL 1449: пользователь, указанный как определитель, не существует

решение заключалось в том, чтобы удалить триггеры в этой таблице и снова создать их снова, это устранило проблему, поскольку триггер был сделан с другим пользователем с другого сервера, а имя пользователя изменилось на новом сервере после изменения компании-хостинга. что мои 2 цента

At one of our customers there is an Active Directory that contains several domains. There are overlapping user accounts in these domains, like DomainAUser1 and DomainBUser1, often one of these accounts is disabled, while the same account in the other domain is active.

Recently I worked with a list, where I chose a user in People picker without problems, however, when saving the list item, I received an error:

The user does not exist or is not unique.<nativehr>0x81020054</nativehr><nativestack></nativestack>

image

The full stack trace:

[COMException (0x81020054): The user does not exist or is not unique.<nativehr>0x81020054</nativehr><nativestack></nativestack>]
   Microsoft.SharePoint.Library.SPRequestInternalClass.AddOrUpdateItem(String bstrUrl, String bstrListName, Boolean bAdd, Boolean bSystemUpdate, Boolean bPreserveItemVersion, Boolean bUpdateNoVersion, Int32& plID, String& pbstrGuid, Guid pbstrNewDocId, Boolean bHasNewDocId, String bstrVersion, Object& pvarAttachmentNames, Object& pvarAttachmentContents, Object& pvarProperties, Boolean bCheckOut, Boolean bCheckin, Boolean bMigration, Boolean bPublish, String bstrFileName, ISP2DSafeArrayWriter pListDataValidationCallback, ISP2DSafeArrayWriter pRestrictInsertCallback, ISP2DSafeArrayWriter pUniqueFieldCallback) +0
   Microsoft.SharePoint.Library.SPRequest.AddOrUpdateItem(String bstrUrl, String bstrListName, Boolean bAdd, Boolean bSystemUpdate, Boolean bPreserveItemVersion, Boolean bUpdateNoVersion, Int32& plID, String& pbstrGuid, Guid pbstrNewDocId, Boolean bHasNewDocId, String bstrVersion, Object& pvarAttachmentNames, Object& pvarAttachmentContents, Object& pvarProperties, Boolean bCheckOut, Boolean bCheckin, Boolean bMigration, Boolean bPublish, String bstrFileName, ISP2DSafeArrayWriter pListDataValidationCallback, ISP2DSafeArrayWriter pRestrictInsertCallback, ISP2DSafeArrayWriter pUniqueFieldCallback) +406

[SPException: The user does not exist or is not unique.]
   Microsoft.SharePoint.SPGlobal.HandleComException(COMException comEx) +27609794
   Microsoft.SharePoint.Library.SPRequest.AddOrUpdateItem(String bstrUrl, String bstrListName, Boolean bAdd, Boolean bSystemUpdate, Boolean bPreserveItemVersion, Boolean bUpdateNoVersion, Int32& plID, String& pbstrGuid, Guid pbstrNewDocId, Boolean bHasNewDocId, String bstrVersion, Object& pvarAttachmentNames, Object& pvarAttachmentContents, Object& pvarProperties, Boolean bCheckOut, Boolean bCheckin, Boolean bMigration, Boolean bPublish, String bstrFileName, ISP2DSafeArrayWriter pListDataValidationCallback, ISP2DSafeArrayWriter pRestrictInsertCallback, ISP2DSafeArrayWriter pUniqueFieldCallback) +28003791
   Microsoft.SharePoint.SPListItem.AddOrUpdateItem(Boolean bAdd, Boolean bSystem, Boolean bPreserveItemVersion, Boolean bNoVersion, Boolean bMigration, Boolean bPublish, Boolean bCheckOut, Boolean bCheckin, Guid newGuidOnAdd, Int32& ulID, Object& objAttachmentNames, Object& objAttachmentContents, Boolean suppressAfterEvents, String filename) +26729773
   Microsoft.SharePoint.SPListItem.UpdateInternal(Boolean bSystem, Boolean bPreserveItemVersion, Guid newGuidOnAdd, Boolean bMigration, Boolean bPublish, Boolean bNoVersion, Boolean bCheckOut, Boolean bCheckin, Boolean suppressAfterEvents, String filename) +26726382
   Microsoft.SharePoint.SPListItem.Update() +161
   Microsoft.SharePoint.WebControls.SaveButton.SaveItem(SPContext itemContext, Boolean uploadMode, String checkInComment) +20288612
   Microsoft.SharePoint.WebControls.SaveButton.OnBubbleEvent(Object source, EventArgs e) +1315
   System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +70
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +29
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2981

A similar error can we reproduce when selecting a user in People picker, then before save, we set the account in AD as disabled:

image

When saving the item, the same “The user does not exist or is not unique” exception is thrown as long the user was not yet available in the user list of SharePoint. If the user was already former created in the SharePoint user list, there was no error, even if the user was disabled in AD.

However, in our case, it was a bit more complicated. When I searched the user in People picker, only one of the accounts was shown up, the one that was not disabled (in this case, from DomainA). The disabled account from the other domain was not included in the People picker. So far, so good.

image

However, after I selected the user and closed the People picker by pressing OK, the other, disabled user (from DomainB) was set in the field, and caused the issue at save.

image

When I set the account by explicitly specifying the domain (like DomainAtestuser) I hade no such problems.

After a user from DomainB was resolved by People picker, both accounts was shown up in the result list (at least, for a while).

I’ve created a few network traffic capture using Wireshark, and found that the LDAP queries again the AD were correct, searching only accounts that are not disabled (see condition (!(userAccountControl:1.2.840.113556.1.4.803:=2) below).

(&(&(&(objectCategory=person)(objectClass=user))(!(userAccountControl:1.2.840.113556.1.4.803:=2)))(|(|(|(|(|(|(|(name=testuser*)(displayName=testuser*))(cn=testuser*))(mail=testuser*))(sn=testuser*))(SamAccountName=testuser*))

The response from AD was OK as well, including only the active user from DomainA.

Using SQL Server Profiler I found queries, like the ones below:

exec sp_executesql N’DECLARE @DocParentIdForRF uniqueidentifier SELECT TOP 1 @DocParentIdForRF = Docs.Id FROM Docs WHERE Docs.SiteId = @SITEID AND Docs.DirName = @FDN AND Docs.LeafName = @FLN;   SELECT TOP(@NUMROWS) t1.[Type] AS c0, UserData.[tp_ContentTypeId], UserData.[nvarchar10], UserData.[tp_ID], UserData.[tp_CopySource], UserData.[tp_Version], t1.[Id] AS c4, UserData.[nvarchar4], UserData.[nvarchar9], UserData.[nvarchar5], UserData.[tp_Created], t1.[SortBehavior] AS c1, UserData.[tp_HasCopyDestinations], UserData.[nvarchar1], UserData.[tp_ModerationStatus], UserData.[tp_Level], UserData.[nvarchar6], t1.[MetaInfo] AS c3, t1.[ScopeId] AS c5, UserData.[tp_Modified], CASE WHEN DATALENGTH(t1.DirName) = 0 THEN t1.LeafName WHEN DATALENGTH(t1.LeafName) = 0 THEN t1.DirName ELSE t1.DirName + N”/” + t1.LeafName END  AS c2, UserData.[nvarchar3] FROM UserData INNER MERGE JOIN Docs AS t1 WITH(NOLOCK) ON (UserData.[tp_RowOrdinal] = 0) AND (t1.SiteId=UserData.tp_SiteId) AND (t1.SiteId = @SITEID) AND (t1.ParentId = UserData.tp_ParentId) AND (t1.Id = UserData.tp_DocId) AND ( (UserData.tp_Level = 1) ) AND (t1.Level = UserData.tp_Level) AND (t1.IsCurrentVersion = 1) AND (t1.Level = 1 OR t1.Level =  2) WHERE ( (UserData.tp_Level = 1) ) AND (UserData.tp_SiteId=@SITEID AND (UserData.tp_ParentId=@DocParentIdForRF)) AND (UserData.tp_RowOrdinal=0) AND ((UserData.[bit3]=0 ) AND ((UserData.[tp_ContentTypeId] = @L2IMG) AND (((UserData.[nvarchar3] LIKE @L3TXP) OR (UserData.[nvarchar1] LIKE @L4TXP)) OR ((UserData.[nvarchar4] LIKE @L4TXP) OR (UserData.[nvarchar5] LIKE @L3TXP)))) AND t1.SiteId=@SITEID AND (t1.ParentId=@DocParentIdForRF)) ORDER BY UserData.[nvarchar3]  ASC ,UserData.[tp_ID]  ASC  OPTION (FORCE ORDER, MAXDOP 1)’,N’@LFFP uniqueidentifier,@SITEID uniqueidentifier,@L2IMG varbinary(8000),@L3TXP nvarchar(4000),@L4TXP nvarchar(4000),@FDN nvarchar(4000),@FLN nvarchar(4000),@NUMROWS bigint,@RequestGuid uniqueidentifier’,@LFFP=’00000000-0000-0000-0000-000000000000′,@SITEID=’94053632-22BC-4CEA-A146-8EC049097DA3′,@L2IMG=0x010A00980232D0CB4C3C41A835ED215B890946,@L3TXP=N’%DomainAtestuser%’,@L4TXP=N’DomainAtestuser%’,@FDN=N’my/_catalogs’,@FLN=N’users’,@NUMROWS=12,@RequestGuid=’5DBABDC5-3182-4866-8FBC-0E9244FE6733′

and

exec proc_SecResolvePrincipal @SiteId=’94053632-22BC-4CEA-A146-8EC049097DA3′,@Input=N’DomainAtestuser’,@InputIsEmailOnly=0,@AccountName=N’DomainAtestuser’,@DLAlias=NULL,@DLAliasServerAddress=NULL,@SearchScope=1,@RequestGuid=’5DBABDC5-3182-4866-8FBC-0E9244FE6733′

While the user did not yet exist in the SharePoint site, neither of these queries had a result.

Using Reflector I found that the following classes and methods have significant roles in the user login name resolution:

Microsoft.SharePoint.Utilities.SPUtility class, ResolvePrincipalInternal, ResolveWindowsPrincipal, SearchAgainstAD methods
Microsoft.SharePoint.WebControls.PeopleEditor class, GetAccountFromSid method
Microsoft.SharePoint.Utilities.SPActiveDirectoryPrincipalBySIDResolver class, ResolvePrincipal method
Microsoft.SharePoint.Utilities.SPUserUtility class, ResolveAgainstUserInfoList method
System.Security.Principal.NTAccount class, Translate and TranslateToSids methods

There are a few approach to resolve the user via the methods above:

SPPrincipalInfo pi = SPUtility.ResolveWindowsPrincipal(web.Site.WebApplication, «testuser», SPPrincipalType.User, false);

or

SecurityIdentifier sid = (SecurityIdentifier)new NTAccount(«testuser»).Translate(typeof(SecurityIdentifier));

or using Reflection through the internal static GetAccountFromSid method of the PeopleEditor class:

  1. byte[] binaryForm = null;
  2. string ntAccountName = null;
  3. string domainName = null;
  4. string userName = null;
  5.  
  6. string lookUpName = «testuser»;
  7. Console.WriteLine(«Account name to be resolved: {0}», lookUpName);
  8.  
  9. SecurityIdentifier sid = (SecurityIdentifier)new NTAccount(lookUpName).Translate(typeof(SecurityIdentifier));
  10. binaryForm = new byte[sid.BinaryLength];
  11. sid.GetBinaryForm(binaryForm, 0);
  12.  
  13. Console.WriteLine(«{0} (Original SID)», sid);
  14.  
  15. // call internal static method PeopleEditor.GetAccountFromSid
  16. object sidTypeInvalid = null;
  17. // sidTypeInvalid = SPAdvApi32.SID_NAME_USE.SidTypeInvalid;
  18. // hack to get the Microsoft.SharePoint assembly
  19. Assembly spAssembly = typeof(SPWeb).Assembly;
  20.  
  21. // get the internal enum type from the internal class
  22. Type sidNameUseType = spAssembly.GetType(«Microsoft.SharePoint.Win32.SPAdvApi32+SID_NAME_USE»);
  23. FieldInfo fi_SidTypeInvalid = sidNameUseType.GetField(«SidTypeInvalid», BindingFlags.Public | BindingFlags.Static);
  24. sidTypeInvalid = fi_SidTypeInvalid.GetValue(null);
  25. MethodInfo mi_GetAccountFromSid = typeof(PeopleEditor).GetMethod(«GetAccountFromSid», BindingFlags.NonPublic | BindingFlags.Static);
  26. ntAccountName = mi_GetAccountFromSid.Invoke(null, new object[] { binaryForm, userName, domainName, sidTypeInvalid }) as string;
  27. //pe.GetAccountFromSid(binaryForm, out userName, out domainName, out sidUse)
  28. SecurityIdentifier sid2 = (SecurityIdentifier)new NTAccount(ntAccountName).Translate(typeof(SecurityIdentifier));
  29. Console.WriteLine(«Account name found: {0}», ntAccountName);
  30. Console.WriteLine(«{0} (SID after GetAccountFromSid)», sid2);

We can use the public instance methods of the PeopleEditor class from a console application as well, however, in this case we have to inject a dummy HTTP context first.

  1. // inject fake context
  2. HttpRequest request = new HttpRequest(string.Empty, web.Url, string.Empty);
  3. HttpResponse response = new HttpResponse(new System.IO.StreamWriter(new System.IO.MemoryStream()));
  4. HttpContext dummyContext = new HttpContext(request, response);
  5. dummyContext.Items[«HttpHandlerSPWeb»] = web;
  6. HttpContext.Current = dummyContext;
  7. PeopleEditor pe = new PeopleEditor();
  8.  
  9. // method 1
  10. ArrayList resolvedAccounts = pe.ResolveAccountsByArrKeys(new string[] { «testuser» });
  11.  
  12. // method 2
  13. PickerEntity entity = new PickerEntity();
  14. entity.Key = «testuser»;
  15. var entity2 = pe.ValidateEntity(entity);

I found that the source of the issue might be the Translate method of the NTAccount class. If I call this method first (or after a long while) with the account name (like ‘testuser’), the SID of the disabled account is returned. When calling the method with the full login name (like ‘DomainAtestuser’ or ‘DomainBtestuser’), the SID of the corresponding user is returned. However, when we call the method with the account name (like ‘testuser’) just after we called the method with the full login name (like ‘DomainAtestuser’), the SID of the active user is returned. It seems that there is a sort of caching implemented somewhere in these objects, but since they are rather complex, including calls into unmanaged code, I was not (yet) able to resolve the issue of user name resolution.

Describe the bug
The Auth.signIn method now returns a userNotFoundException even though the user exists in the cognito user pool.

I had an existing and fully functioning auth flow working through cognito for my react-native app. However, I, realized that I needed to create and use a new cognito user pool for my app, and delete the old user pool. I achieved this via the amplify-cli. All seemed well when I did a sign up test in the app. The user could create an account, receive a verification code in their email, and the cognito user pool responded appropriately. However, when that same user that was just created attempts to sign in, the Auth.signIn method throws a userNotFoundException error.

To Reproduce
Assuming the app already as Auth added
In the terminal run:

  1. amplify remove auth
    Confirm removal
  2. amplify push
    Confirm push
  3. amplify add auth
    Select default configuration with social providers and conduct a standard setup
  4. Rebuild the App
  5. Create a new user via the Auth.signUp method (in app, this is just the standard auth flow)
  6. Attempt to sign in with the just-created user.

Expected behavior
The Auth.signIn method should return a successful sign in.

Code Snippet
Error:
error signing in... {code: "UserNotFoundException", name: "UserNotFoundException", message: "User does not exist."}

Context of Auth.signIn method:

import React, { Component, useState, useContext } from 'react' import {AuthContext} from '../../navigation/Screens'; import {ToggleContext} from './Auth'; import { View, TouchableWithoutFeedback, StyleSheet } from 'react-native' import { Text } from 'galio-framework'; import { Auth } from 'aws-amplify' import argonTheme from '../../constants/argonTheme'; import Input from '../../components/Auth/Input' import ActionButton from '../../components/Auth/ActionButton' import SocialButton from '../../components/Auth/SocialButton'; import GoogleButton from '../../components/Auth/GoogleButton'; // Sign in screen function SignIn() { // Assigns updateAuth function to a variable // Assigns toggleAuthType function to a variable const updateAuth = useContext(AuthContext); const toggleAuthType = useContext(ToggleContext); // Username and Password state management via useState hooks const [username, setUsername] = useState(''); const [password, setPassword] = useState(''); // Sign In function // Attempts to sign in with given username and password // * Note that Auth.signIn returns a promise in the form of an object // Sets current view to the main app if the Auth.signIn promise resolves to a success // Logs error and alerts if the Auth.Sign promise resolves to a failure async function signIn() { try { await Auth.signIn(username, password) console.log('successfully signed in') updateAuth('MainNav') } catch (code) { console.log('error signing in...', code) alert(code.message) } } function showForgotPassword() { toggleAuthType('showForgotPassword') } return ( <View> <Input onChangeText={(text) => {setUsername(text)}} type='username' placeholder='Username' /> <Input onChangeText={(text) => {setPassword(text)}} type='password' placeholder='Password' secureTextEntry /> <ActionButton title='Sign In' onPress={signIn} BGColor={argonTheme.COLORS.ACTIVE} /> <View style={styles.buttonContainer}> <TouchableWithoutFeedback onPress={showForgotPassword}> <Text style={{fontSize: 16, fontFamily: 'OpenSans-regular'}}>Forget your password?</Text> </TouchableWithoutFeedback> </View> <View style={styles.buttonContainer}> <Text style={{fontSize: 16, fontFamily: 'OpenSans-regular'}}>Or</Text> </View> <View style={styles.socialCont}> <GoogleButton title="Sign in with Google" onPress={() => Auth.federatedSignIn({ provider: "Google" })} /> <SocialButton title="Sign in with Facebook" onPress={() => Auth.federatedSignIn({ provider: "Facebook" })} BGColor={argonTheme.COLORS.FACEBOOK} iconName='facebook' iconColor='white' textColor={argonTheme.COLORS.WHITE} /> <SocialButton title="Sign in with Apple" BGColor={argonTheme.COLORS.BLACK} iconName='apple' iconColor='white' textColor={argonTheme.COLORS.WHITE} /> </View> </View> ) } const styles = StyleSheet.create({ buttonContainer: { paddingTop: '2%', justifyContent: 'center', flexDirection: 'row', }, socialCont: { marginTop: '5%' }, }) export default SignIn 

aws-exports.js

const awsmobile = { "aws_project_region": "us-east-2", "aws_cognito_identity_pool_id": "us-east-2:d15b3200-6cc2-4e28-9ef0-334cdfa3c389", "aws_cognito_region": "us-east-2", "aws_user_pools_id": "us-east-2_uZqiPEd19", "aws_user_pools_web_client_id": "1npgiokobk2d10ofoerablv93t", "oauth": { "domain": "nerdhub-auth-dev.auth.us-east-2.amazoncognito.com", "scope": [ "phone", "email", "openid", "profile", "aws.cognito.signin.user.admin" ], "redirectSignIn": "http://localhost:3000/", "redirectSignOut": "http://localhost:3000/", "responseType": "code" }, "federationTarget": "COGNITO_USER_POOLS" }; 

parameters.json

{ "identityPoolName": "nerdhub39718c9f_identitypool_39718c9f", "allowUnauthenticatedIdentities": false, "resourceNameTruncated": "nerdhu39718c9f", "userPoolName": "nerdhub39718c9f_userpool_39718c9f", "autoVerifiedAttributes": [ "email" ], "mfaConfiguration": "OFF", "mfaTypes": [ "SMS Text Message" ], "smsAuthenticationMessage": "Your authentication code is {####}", "smsVerificationMessage": "Your verification code is {####}", "emailVerificationSubject": "Your verification code", "emailVerificationMessage": "Your verification code is {####}", "defaultPasswordPolicy": false, "passwordPolicyMinLength": 8, "passwordPolicyCharacters": [], "requiredAttributes": [ "email" ], "userpoolClientGenerateSecret": true, "userpoolClientRefreshTokenValidity": 30, "userpoolClientWriteAttributes": [ "email" ], "userpoolClientReadAttributes": [ "email" ], "userpoolClientLambdaRole": "nerdhu39718c9f_userpoolclient_lambda_role", "userpoolClientSetAttributes": false, "sharedId": "39718c9f", "resourceName": "nerdhub39718c9f", "authSelections": "identityPoolAndUserPool", "authRoleArn": { "Fn::GetAtt": [ "AuthRole", "Arn" ] }, "unauthRoleArn": { "Fn::GetAtt": [ "UnauthRole", "Arn" ] }, "useDefault": "defaultSocial", "hostedUI": true, "hostedUIDomainName": "nerdhub-auth", "authProvidersUserPool": [ "Facebook", "Google" ], "hostedUIProviderMeta": "[{"ProviderName":"Facebook","authorize_scopes":"email,public_profile","AttributeMapping":{"email":"email","username":"id"}},{"ProviderName":"Google","authorize_scopes":"openid email profile","AttributeMapping":{"email":"email","username":"sub"}}]", "oAuthMetadata": "{"AllowedOAuthFlows":["code"],"AllowedOAuthScopes":["phone","email","openid","profile","aws.cognito.signin.user.admin"],"CallbackURLs":["http://localhost:3000/"],"LogoutURLs":["http://localhost:3000/"]}", "userPoolGroupList": [], "dependsOn": [] } 

Environment
System:
OS: macOS 10.15.4
CPU: (8) x64 Intel(R) Core(TM) i5-1038NG7 CPU @ 2.00GHz
Memory: 16.45 MB / 16.00 GB
Shell: 5.7.1 — /bin/zsh
Binaries:
Node: 12.14.1 — /usr/local/bin/node
Yarn: 1.22.4 — /usr/local/bin/yarn
npm: 6.14.5 — /usr/local/bin/npm
Browsers:
Chrome: 84.0.4147.105
Safari: 13.1
npmPackages:
@apollo/react-hooks: ^3.1.5 => 3.1.5
@aws-amplify/pubsub: ^2.1.9 => 2.1.9
@babel/core: ^7.9.0 => 7.9.0
@babel/runtime: ^7.9.2 => 7.9.2
@expo/vector-icons: ^10.0.6 => 10.0.6
@react-native-community/eslint-config: ^1.1.0 => 1.1.0
@react-native-community/google-signin: ^4.0.0 => 4.0.0
@react-native-community/masked-view: ^0.1.9 => 0.1.9
@react-native-community/netinfo: ^5.9.2 => 5.9.5
@react-navigation/bottom-tabs: ^5.2.7 => 5.2.7
@react-navigation/compat: ^5.1.9 => 5.1.9
@react-navigation/drawer: ^5.5.0 => 5.5.0
@react-navigation/material-top-tabs: ^5.2.2 => 5.2.8
@react-navigation/native: ^5.2.6 => 5.4.3
@react-navigation/stack: ^5.2.11 => 5.2.11
@unimodules/core: ^5.1.0 => 5.1.0
@unimodules/react-native-adapter: ^5.2.0 => 5.2.0
amazon-cognito-identity-js: ^4.3.1 => 4.3.3
apollo-boost: ^0.4.9 => 0.4.9
aws-amplify: ^2.3.0 => 2.3.0
aws-amplify-react-native: ^4.2.0 => 4.2.1
babel-jest: ^25.3.0 => 25.3.0
eslint: ^6.8.0 => 6.8.0
expo-asset: ^8.1.4 => 8.1.4
expo-constants: ^9.0.0 => 9.0.0
expo-file-system: ^8.1.0 => 8.1.0
expo-font: ^8.1.1 => 8.1.1
galio-framework: ^0.6.3 => 0.6.3
graphql: ^14.6.0 => 14.7.0
jest: ^25.3.0 => 25.3.0
metro-react-native-babel-preset: ^0.59.0 => 0.59.0
prop-types: ^15.7.2 => 15.7.2
react: ^16.11.0 => 16.13.1
react-native: 0.62.2 => 0.62.2
react-native-elements: ^1.2.7 => 1.2.7
react-native-gesture-handler: ^1.6.1 => 1.6.1
react-native-inappbrowser-reborn: ^3.4.0 => 3.4.0
react-native-material-dropdown: ^0.11.1 => 0.11.1
react-native-material-tabs: ^4.1.2 => 4.1.2
react-native-reanimated: ^1.8.0 => 1.8.0
react-native-safe-area-context: ^0.7.3 => 0.7.3
react-native-screens: ^2.5.0 => 2.5.0
react-native-snap-carousel: ^3.9.1 => 3.9.1
react-native-splash-screen: ^3.2.0 => 3.2.0
react-native-tab-view: ^2.14.0 => 2.14.2
react-native-vector-icons: ^6.6.0 => 6.6.0
react-native-view-more-text: ^2.1.0 => 2.1.0
react-test-renderer: 16.11.0 => 16.11.0
typescript: ^3.8.3 => 3.8.3
npmGlobalPackages:
@aws-amplify/cli: 4.21.0
create-react-app: 3.4.0
expo-cli: 3.15.5
firebase-tools: 8.4.0
gatsby-cli: 2.12.17
gulp: 4.0.2
npm: 6.14.5
react-native-cli: 2.0.1

Smartphone (please complete the following information):

  • Device: iPhone 11
  • OS: IOS 13.6
  • Browser: safari

Forgive me if this is a simple fix, I am quite new to SQL, just started learning it on Tuesday. So I am experimenting with functions and made a simple one to test it out such as

CREATE FUNCTION CHINOOKHW.AddPara(@a1 int, @b2 int)
RETURN INT
BEGIN AS
  DECLARE @C3 INT = SUM(A1, B2)
  RETURN @C3
END
GO
CHINOOKHW.AddPara(1, 2);

but I get the error

Error report -
ORA-01435: user does not exist
01435. 00000 -  "user does not exist"
*Cause:    
*Action:

I have already defined my user as

CREATE USER chinookhw
IDENTIFIED BY p4ssw0rd;

And while I know this is normally bad practice, I even gave my user all access like

GRANT ALL PRIVILEGES to chinookhw IDENTIFIED BY p4ssw0rd;

I am not sure if this is relevant but I a connected to the chinook database from
https://chinookdatabase.codeplex.com/

and I made another connection from the system database with the lines

GRANT DBA TO chinook;
GRANT DBA TO chinookhw;
commit;

Can anyone tell me what I am doing wrong? I’ve been at this for hours with no fix. Thank you in advance

by Tashreef Shareef

Tashreef Shareef is a software developer turned tech writer. He discovered his interest in technology after reading a tech magazine accidentally. Now he writes about everything tech from… read more


Updated on August 26, 2020

XINSTALL BY CLICKING THE DOWNLOAD FILE

Try Outbyte Driver Updater to resolve driver issues entirely:
This software will simplify the process by both searching and updating your drivers to prevent various malfunctions and enhance your PC stability. Check all your drivers now in 3 easy steps:

  1. Download Outbyte Driver Updater.
  2. Launch it on your PC to find all the problematic drivers.
  3. Afterward, Click Update & Apply Selected to get the latest driver versions.
  • OutByte Driver Updater has been downloaded by 0 readers this month.

Sometimes while trying to connect to a specific server on your Windows server machine, the request may fail with an error. One such error is “the specified user does not exist, verify the username ad try logging in again. If the problem continues, contact your system administrator or technical support”. This error can occur due to many reasons including faulty Windows updates as reported by other users in the Microsoft Technet forums.

when exporting to AD destination (active directory server installed on windows server 2003) i get the following error messages for CNswhich are groups:
“DN-attributes failure – The specified user does not exist”
Connected data source error code 1317
Connected data source error: The spcified user does not exist
also in the connector space object properties for those objects i can see in “pending export tab” the info:
modification type update
object type group

Follow the steps in this article to troubleshoot the specified user does not exist error in Windows Server systems.

How to Fix the specified user does not exist

1. Check for NAS for Permissions

the specified user does not exist

  1. If the error is occurring while trying to set up backup to disk folders in backup exec, you may want to check if the appropriate permissions are given to the folder on the NAS.
  2. Similar to EMC, you need to specify folder permissions on the NAS folder itself to make it work without any error.
  3. Check the resources related to Exec Backup to check for the required permissions.

Windows Server could not mount ISO files: Here’s how to fix it


2. Specify the User for the Service

the specified user does not exist

  1. One of the obvious yet common mistakes people do is not specify the username for the service accounts in form of domain/username where you had the username.
  2. When the server fails to find the username for the account, it will show the specified user does not exist error.
  3. To fix this, check if you have specified username for the service accounts and then check for any improvements.

3. Delete and Create a New Account

the specified user does not exist

  1. If the error on the login level, you may want to create a new user account with administrator rights.
  2. Make sure you use a different variation of your first name to create the new account. Using the same name as the old one may not resolve the issue completely.
  3. After creating a new account and signing in, make sure add yourself to some groups in AD to access to necessary things.
  4. If the error occurs again, remove your account from all the non-essential groups one by one and try to login in between. The issue can be due to one of the groups that you are a member of.

4. Clear Windows Password Vault

the specified user does not exist

  1. If you save all of your credentials with Windows Password Vault / Credential Manager, try to remove all the credentials related to the server.
  2. Now try to login again and Windows server will ask you enter the password. Make sure you don’t select save password option this time.
  3. Manually entering the credentials should help you resolve the specified user does not exist error.

RELATED STORIES YOU MAY LIKE:

  • How to install Docker on Windows Server (2016 and later)
  • FIX: Windows Server AppFabric is not correctly configured
  • How to enable Remote Desktop on Windows Server 2019

Still experiencing troubles? Fix them with this tool:

SPONSORED

Some driver-related issues can be solved faster by using a tailored driver solution. If you’re still having problems with your drivers, simply install OutByte Driver Updater and get it up and running immediately. Thus, let it update all drivers and fix other PC issues in no time!

newsletter icon

В качестве дополнения, чтобы изменить определитель для TRIGGERS (ALTER не работает), вы можете сделать это следующим образом:

Создайте команду DROP и CREATE для каждого триггера:

SELECT CONCAT("DROP TRIGGER ", trigger_name, ";", " CREATE TRIGGER ", TRIGGER_NAME, " AFTER ", EVENT_MANIPULATION, " ON ", EVENT_OBJECT_SCHEMA, ".", EVENT_OBJECT_TABLE, " FOR EACH ROW ", ACTION_STATEMENT, ";") AS sqlCommand FROM information_schema.triggers WHERE EVENT_OBJECT_SCHEMA = "yourdatabase";

Выполните его в foreach. Я использую это в своем приложении, когда беру производственную базу данных на свою машину разработки и отправляю ее с помощью foreach по всем командам и автоматически создаю триггеры. Это дает мне возможность автоматизировать его.

Пример в PHP/Laravel:

    $this->info('DROP and CREATE TRIGGERS');
    $pdo = DB::connection()->getPdo();
    $sql = 'SELECT CONCAT("DROP TRIGGER ", trigger_name, ";", " CREATE TRIGGER ", TRIGGER_NAME, " AFTER ", EVENT_MANIPULATION, " ON ", EVENT_OBJECT_SCHEMA, ".", EVENT_OBJECT_TABLE, " FOR EACH ROW ", ACTION_STATEMENT, ";") AS sqlCommand FROM information_schema.triggers WHERE EVENT_OBJECT_SCHEMA = "mydatabase";';
    $stmt = $pdo->prepare($sql, [PDO::MYSQL_ATTR_USE_BUFFERED_QUERY => true]);
    $stmt->execute();
    $result = $stmt->fetchAll(PDO::FETCH_ASSOC);
    $stmt->closeCursor();

    foreach($result as $rs){
        $pdo = DB::unprepared($rs['sqlCommand']);
        break;
    }

Подсказка: я должен сделать это с pdo из-за проблемы с запросом буфера mysql, описанного здесь

  • Ошибка vanguard anti cheat valorant 1067
  • Ошибка van 9001 valorant windows 11
  • Ошибка valvetronic bmw x5 e70
  • Ошибка valvetronic bmw n55
  • Ошибка valvetronic bmw e90 n46